package com.gaojinqi.order.controller;

import com.gaojinqi.order.message.SendingBean;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.Date;

/**
 * @author gaojinqi
 * @date 2019/5/26 22:38
 */
@RestController
public class SendMessageController {

    @Autowired
    private SendingBean sendingBean;

    @GetMapping("/sendMessage")
    public void process(){
        String message = "now " + new Date();
        sendingBean.sendWithOutput(message+"ooo");
        sendingBean.sendWith(message);
    }

}
